package xyz.robinbingo.effectivejava.chapter04.item15;

import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import java.util.List;

/**
 * @author Robin
 * @date 2019/03/21 15:33
 **/
@RunWith(SpringRunner.class)
@SpringBootTest
public class Item15 {
    // Potential security hole!
    public static final String[] VALUES = {"a", "b"};

    private static final String[] PRIVATE_VALUES = {"a", "b", "c"};
    public static final List<String> VALUES1 = List.of(PRIVATE_VALUES);

    private static final String[] PRIVATE_VALUES1 = {"a", "b", "c", "d"};

    public static final String[] values() {
        return PRIVATE_VALUES1.clone();
    }
}
